﻿using System;

namespace EvaluationSystem
{
    public partial class SiteAnswerMaster : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                if (Request.QueryString["weltext"] != null)
                {
                    LabelWelcome.Text = Request.QueryString["weltext"].ToString();
                }
                if (Request.QueryString["logopath"] != null)
                {
                    if (string.IsNullOrEmpty(Request.QueryString["logopath"].ToString().Replace("\\", "/")))
                    {
                        ImageLogo.Visible = false;
                    }
                    else
                    {
                        ImageLogo.ImageUrl = "~/userfiles" + "\\" +
                            Request.QueryString["logopath"].ToString();
                    }
                }
                if (Request.QueryString["atext"] != null)
                {
                    txtIntro.Text = Request.QueryString["atext"].ToString();
                }
                if (Request.QueryString["ctext"] != null)
                {
                    txtIntro.Text += Environment.NewLine + Environment.NewLine
                                    + Request.QueryString["ctext"].ToString();
                }
            }
        }
    }
}
